<!DOCTYPE html>
<html>
	<head>
		<meta charset="utf-8" />
		<meta name="viewport" content="initial-scale=1.0, maximum-scale=1.0, user-scalable=no" />
		<meta name="HandheldFriendly" content="true" />
		<meta name="MobileOptimized" content="320" />
		<link rel="stylesheet" href="./css/reset.css">
		<link rel="stylesheet" href="./css/jiazai.css">
		<link rel="stylesheet" type="text/css" href="css/no-noodel.css" />
		<title>待出餐</title>
		<style>
			[v-cloak] {
				display: none;
			}
			
		</style>
	</head>
	<body>
		<div id="app" v-cloak>
			<!-- 加载中动画 -->
			<div id='jiazai-ani' v-if='jiazai'>
				<div class="arc"></div>
				<h1><span>LOADING</span></h1>
			</div>
			<!-- 加载中动画 -->
			<div class="wrap-par">
				<div class="one-order-wrap" v-for="(val,index) in 10" :key='index'>
					<div class="order-par">
						<div class="order-time-par dis-spa">
							<div class="dis-start order-time">
								<span>下单时间：</span>
								<span>2019-20-10 10:45</span>
							</div>
						</div>
						<div class="dis-spa order-imgs-par">
							<div class="order-goods-imgs">
								<img src="https://timgsa.baidu.com/timg?image&quality=80&size=b9999_10000&sec=1572709080924&di=835f8a1c308fd61a42b113af7ea8ef59&imgtype=0&src=http%3A%2F%2Fp0.meituan.net%2Fdealwatera%2F840068c490d61fbe222913064e49017772741.jpg%40527h_702w_2e_90Q%257Cwatermark%3D1%26%26p%3D4">
								<img src="http://www.yaojiameng.net/file/upload/201610/11/1101548136.jpg">
								<img src="http://www.yaojiameng.net/file/upload/201610/11/1101548136.jpg">
								<img src="http://www.yaojiameng.net/file/upload/201610/11/1101548136.jpg">
								<img src="http://www.yaojiameng.net/file/upload/201610/11/1101548136.jpg">
								<img src="http://www.yaojiameng.net/file/upload/201610/11/1101548136.jpg">
								<img src="http://www.yaojiameng.net/file/upload/201610/11/1101548136.jpg">
								<img src="http://www.yaojiameng.net/file/upload/201610/11/1101548136.jpg">
								<img src="http://www.yaojiameng.net/file/upload/201610/11/1101548136.jpg">
								<img src="http://www.yaojiameng.net/file/upload/201610/11/1101548136.jpg">
								<img src="http://www.yaojiameng.net/file/upload/201610/11/1101548136.jpg">
							</div>
							<div class="dis-cen order-number">
								<div class="order-num">
									10
								</div>
							</div>
						</div>
						<div class="dis-spa order-other">
							<div class="dis-start">
								<span>优惠：</span>
								<span>30元</span>
							</div>
							<div class="dis-start">
								<span>实付：</span>
								<span>40元</span>
							</div>
							<div class="dis-start">
								<span>数量：</span>
								<span>40</span>
							</div>
						</div>
						<div class="order-btn">
							<div>
								已取餐
							</div>
							<div>
								叫号
							</div>
						</div>
					</div>
					<div class="bar">
					</div>
				</div>
			</div>
		</div>
		<script src="js/comm.js" type="text/javascript" charset="utf-8"></script>
		<script src="js/vue.min.js" type="text/javascript" charset="utf-8"></script>
		<script src="js/mui.min.js" type="text/javascript" charset="utf-8"></script>

		<script type="text/javascript" charset="utf-8">
			var app = new Vue({
				el: '#app',
				data: {
					//控制加载动画
					jiazai: false
				},
				mounted: function() {
					var This = this;
					this.$nextTick(function() {
						This.goWebSocket();
					})
				},
				methods: {
					goWebSocket: function() {
						var ws = new WebSocket("ws://192.168.43.107:9001/websocket/daiqqqaa");

						ws.onopen = function() {
							// Web Socket 已连接上，使用 send() 方法发送数据
							ws.send("发送数据dfsdfgsdfgs");
						};

						ws.onmessage = function(evt) {
							var received_msg = evt.data;
							console.log('数据：' + received_msg)
						};

						ws.onclose = function() {
							// 关闭 websocket
							alert("连接已关闭...");
						};
					}
				}
			});
		</script>

	</body>

</html>
